<style type="text/css" >
	.img_partner {
		width: 170px;
		height: 77px;
	}
</style>

<p class='msview'>
	<span>
		<?php echo $this->session->flashdata('msview'); ?>
	</span>
</p>

<div class="header2"><p class="pHead"><?php echo $title; ?></p></div>
            <div class="contentMain">  
                <form id="frmForm" method="POST" action="<?php echo base_url()?>back_end/partner/delete">
	                <div class="headerSearch tblHead" style="border-bottom:none;">
		                <table class="tbl_head">
		                    <tr>
		                    	<td><input type="submit" class="dlt" value="Xóa" name="delete" /></td>
		                    	<td><a href="<?php echo base_url()?>back_end/partner/add"><img title="Thêm mới" alt="icon" src="<?php echo base_url(); ?>images/back_end/icon/add1.png"></a></td>
		                    	<td class="tag_add"><a href="<?php echo base_url()?>back_end/partner/add">Thêm mới</a></td>
		                    	<td><span class="count_check"></span></td>
		                    </tr>
		                </table>
	                </div><!-- end headerSearch -->
	                
	                <table class="tablePr" width="100%">
	                	<tr class="trPr1">
		                    <td width="5%" class="tdPr7"><input type="checkbox" class="input_checkall" /></td>
		                    <td width="5%" class="tdPr7">
		                    	ID
		                    </td>
		                    <td width="18%" class="tdPr7">
			                	Tên đối tác	
		                    </td>
		                    <td width="30%" class="tdPr7">
			                	Địa chỉ
		                    </td>
		                    <td width="10%" class="tdPr7">
			                	Số điện thoại
		                    </td>
		                    <td width="20%" class="tdPr7">
		                    	Ảnh
		                    </td>
		                    <td width="12%" class="tdPr7">
		                    	<a title="Click để sắp xếp" href="#">Tác vụ</a>
		                    </td>
		                </tr>
		                
		                <?php
		                	$count = 1; 
		                	foreach ($admin_partner as $value) {
		                		$count += 1;	 
		                ?> 
			                <tr class="<?php if ($count%2) { echo 'trPr3'; } else { echo 'trPr2'; }  ?>">
			                    <td class="tdPr7">
			                    	<input class="input_checkbox" type="checkbox"  value="<?php echo $value['id']; ?>" name="value_id[]"/>
			                    </td>
			                    
			                    <td class="tdPr7">
			                    	<?php echo $value['id']; ?>
			                    </td>
			                    
			                    <td class="tdPr7">
			                    	<?php 
			                    		echo $value['name'];
			                    	?>	
			                    </td>
			                    
			                    <td class="tdPr7">
			                    	<?php 
			                    		echo $value['address'];
			                    	?>
			                    </td>
			                   
			                    <td class="tdPr7">
			                    	<?php echo $value['phone']; ?>
			                    </td>
			                    
			                    <td class="tdPr7">
			                    	<?php if ($value['image'] !== NULL) {?>
			                    		<img alt="<?php echo $value['image']; ?>" class="img_partner" src="<?php echo base_url() ?>images/img_product/<?php echo $value['image']; ?>" />
			                    	<?php }?>
			                    </td>
			                    
			                    <td class="tdPr7">
			                    	<?php if($value['status'] == 1) { ?>
			                    		<a class="tag_action" href="<?php echo base_url()?>back_end/partner/active/<?php echo $table.'-'.$value['id'].'-'.'0'.'-'.$table; ?>"><img src="<?php echo base_url()?>images/back_end/icon/check2.png" title="Trạng thái" alt="icon check" /></a>
			                    	<?php } else { ?>
			                 			<a class="tag_action" href="<?php echo base_url()?>back_end/partner/active/<?php echo $table.'-'.$value['id'].'-'.'1'.'-'.$table; ?>"><img src="<?php echo base_url()?>images/back_end/icon/check.png" title="Trạng thái" alt="icon check" /></a>
			                    	<?php }?>
			                    	<a class="tag_action" href="<?php echo base_url()?>/back_end/partner/edit/<?php echo $value['id']; ?>"><img src="<?php echo base_url()?>images/back_end/icon/edit-icon.gif" alt="Sửa" title="Sửa" /></a>
			                    	<a class="tag_action" href="<?php echo base_url()?>back_end/partner/deleteId/<?php echo $value['id']; ?>"><img src="<?php echo base_url()?>images/back_end/icon/delete_png.png" title="Xóa"  alt="icon" /></a>
			                    </td>
		                    </tr>
	                    <?php } ?>
	                </table>
	                
	                <div class="headerSearch tblDel" style="border-top:none;">
	               		<table>
	                    	<tr>
                        		<td><input type="submit" class="dlt" value="Xóa" name="delete" /></td>
	                    		<td><a href="<?php echo base_url()?>back_end/partner/add"><img title="Thêm mới" alt="icon" src="<?php echo base_url(); ?>images/back_end/icon/add1.png"></a></td>
	                    		<td class="tag_add"><a href="<?php echo base_url()?>back_end/partner/add">Thêm mới</a></td>
	                        </tr>
	                    </table>
	                </div><!-- end headerSearch -->
                </form>
                
                <table class="tableLet2" style="margin:10px 10px 0 0;">
                    <tr>
                        <td width="60%" align="right" class="viewNumber" style="padding-right:10px;">
                        	<?php echo $this->pagination->create_links(); ?>
                        </td>
                    </tr>
                  </table>  
                  
            </div><!-- end contentMain -->